package com.zr.eim.service.impl;

import com.zr.eim.domain.EimAnalysisStayPoint;
import com.zr.eim.domain.EimDataPerson;
import com.zr.eim.mapper.EimAnalysisStayPointMapper;
import com.zr.eim.service.IEimAnalysisStayPointService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 停留点信息Service业务层处理
 * 
 * @author peihang
 * @date 2022-10-21
 */
@Service
public class EimAnalysisStayPointServiceImpl implements IEimAnalysisStayPointService 
{
    @Autowired
    private EimAnalysisStayPointMapper eimAnalysisStayPointMapper;

    /**
     * 查询停留点信息
     * 
     * @param id 停留点信息主键
     * @return 停留点信息
     */
    @Override
    public EimAnalysisStayPoint selectEimAnalysisStayPointById(Long id)
    {
        return eimAnalysisStayPointMapper.selectEimAnalysisStayPointById(id);
    }

    /**
     * 查询停留点信息列表
     * 
     * @param eimAnalysisStayPoint 停留点信息
     * @return 停留点信息
     */
    @Override
    public List<EimAnalysisStayPoint> selectEimAnalysisStayPointList(EimAnalysisStayPoint eimAnalysisStayPoint)
    {
        return eimAnalysisStayPointMapper.selectEimAnalysisStayPointList(eimAnalysisStayPoint);
    }

    /**
     * 新增停留点信息
     * 
     * @param eimAnalysisStayPoint 停留点信息
     * @return 结果
     */
    @Override
    public int insertEimAnalysisStayPoint(EimAnalysisStayPoint eimAnalysisStayPoint)
    {
        return eimAnalysisStayPointMapper.insertEimAnalysisStayPoint(eimAnalysisStayPoint);
    }

    /**
     * 修改停留点信息
     * 
     * @param eimAnalysisStayPoint 停留点信息
     * @return 结果
     */
    @Override
    public int updateEimAnalysisStayPoint(EimAnalysisStayPoint eimAnalysisStayPoint)
    {
        return eimAnalysisStayPointMapper.updateEimAnalysisStayPoint(eimAnalysisStayPoint);
    }

    /**
     * 批量删除停留点信息
     * 
     * @param ids 需要删除的停留点信息主键
     * @return 结果
     */
    @Override
    public int deleteEimAnalysisStayPointByIds(Long[] ids)
    {
        return eimAnalysisStayPointMapper.deleteEimAnalysisStayPointByIds(ids);
    }

    /**
     * 删除停留点信息信息
     * 
     * @param id 停留点信息主键
     * @return 结果
     */
    @Override
    public int deleteEimAnalysisStayPointById(Long id)
    {
        return eimAnalysisStayPointMapper.deleteEimAnalysisStayPointById(id);
    }



    @Override
    public List<EimAnalysisStayPoint> selectEimAnalysisStayPointByPersonId(EimDataPerson eimDataPerson) {


        return eimAnalysisStayPointMapper.selectEimAnalysisStayPointByPersonId(eimDataPerson.getPersonId());
    }

    @Override
    public EimAnalysisStayPoint getStayPointByPersonId(EimDataPerson eimDataPerson) {

        return eimAnalysisStayPointMapper.getStayPointByPersonId(eimDataPerson.getPersonId());


    }

}
